881131ac82ccbe94e159dc034f62b95e7bfef85b,Script_1/src/Parser/ASTs/TypeExp_Arr.java,TypeExp_Arr,checkType,#CodeGenerator#,47

Before Change


		return true;
	}
	public boolean checkType(CodeGenerator codegen)throws TypeCheckException{
		return this.type_pre.checkType(codegen);
	}
	
	

After Change


		return true;
	}
	public boolean checkType(CodeGenerator codegen)throws TypeCheckException{
		if(!this.type_pre.checkType(codegen))return false;
		if(this.type_pre==null){
			this.ele_type=this.type_pre.rst_type;
			this.rst_type=this.ele_type;
		}
		T_Type t=codegen.getTypeInSymTb(this.type_pre.rst_type);
		T_Array t1=null;
		if(t.getKType()==T_Type.KType.t_arr){
			t1=((T_Array)t);
			t1.incDims();
			this.ele_type=t1.getEleType();
		}else{
			t1=new T_Array();
			t1.setDims(1);
			this.ele_type=t1.getTypeSig();
		}
		this.rst_type="["+codegen.getTmpSn();			
		codegen.putTypeInSymTb(this.rst_type, t1);
		t1.setKType(T_Type.KType.t_arr);
		this.dim=t1.getDims();
		t1.setTypeSig(this.ele_type+"["+this.dim+"]");
		this.t_type=t1;
		return true;
	}